package easy;

import util.PrintUtils;

public class Solution_1304 {

    public int[] sumZero(int n) {
        int[] arr = new int[n];
        int max = n >> 1;
        boolean zero = n % 2 == 1;
        for (int i = arr.length - 1; i >= 0; i--) {
            if (max == 0 && !zero) {
                max--;
            }
            arr[i] = max--;
        }
        return arr;
    }

    public static void main(String[] args) {
        Solution_1304 model = new Solution_1304();
        PrintUtils.arrayInt(model.sumZero(5));
        PrintUtils.arrayInt(model.sumZero(3));
        PrintUtils.arrayInt(model.sumZero(1));
        PrintUtils.arrayInt(model.sumZero(4));
    }
}
